package com.supervision.manage.mapper

import com.fly.base.mybatis.sqlprovider.SqlProvider
import com.supervision.domain.bean.po.CourtOrgSearchPO
import com.supervision.domain.model.CourtOrg
import com.supervision.manage.mapper.sqlprovider.CourtOrgSqlProvider
import org.apache.ibatis.annotations.Mapper
import org.springframework.stereotype.Component
import org.apache.ibatis.annotations.Param
import org.apache.ibatis.annotations.SelectProvider

@Mapper
@Component
interface CourtOrgMapper {

    @SelectProvider(type = SqlProvider::class, method = "select")
    fun select(@Param("condition") condition: Any, @Param("otherCondition") otherCondition: String?): List<CourtOrg>

    @SelectProvider(type = CourtOrgSqlProvider::class, method = "getCourtOrgList")
    fun getCourtOrgList(po: CourtOrgSearchPO, limitSql: String): List<CourtOrg>

    @SelectProvider(type = CourtOrgSqlProvider::class, method = "getCourtOrgList")
    fun countCourtOrgList(po: CourtOrgSearchPO, limitSql: String): Int
}
